Optimal. Leaf size=112 \[ -\frac {2 \left (a e^2+c d^2\right )}{e^2 \sqrt {d+e x} (e f-d g)}-\frac {2 \left (a g^2+c f^2\right ) \tan ^{-1}\left (\frac {\sqrt {g} \sqrt {d+e x}}{\sqrt {e f-d g}}\right )}{g^{3/2} (e f-d g)^{3/2}}+\frac {2 c \sqrt {d+e x}}{e^2 g} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.22, antiderivative size = 112, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 3, integrand size = 24, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.125, Rules used = {898, 1261, 205} \[ -\frac {2 \left (a e^2+c d^2\right )}{e^2 \sqrt {d+e x} (e f-d g)}-\frac {2 \left (a g^2+c f^2\right ) \tan ^{-1}\left (\frac {\sqrt {g} \sqrt {d+e x}}{\sqrt {e f-d g}}\right )}{g^{3/2} (e f-d g)^{3/2}}+\frac {2 c \sqrt {d+e x}}{e^2 g} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 205
Rule 898
Rule 1261
Rubi steps
\begin {align*} \int \frac {a+c x^2}{(d+e x)^{3/2} (f+g x)} \, dx &=\frac {2 \operatorname {Subst}\left (\int \frac {\frac {c d^2+a e^2}{e^2}-\frac {2 c d x^2}{e^2}+\frac {c x^4}{e^2}}{x^2 \left (\frac {e f-d g}{e}+\frac {g x^2}{e}\right )} \, dx,x,\sqrt {d+e x}\right )}{e}\\ &=\frac {2 \operatorname {Subst}\left (\int \left (\frac {c}{e g}+\frac {c d^2+a e^2}{e (e f-d g) x^2}-\frac {e \left (c f^2+a g^2\right )}{g (-e f+d g) \left (-e f+d g-g x^2\right )}\right ) \, dx,x,\sqrt {d+e x}\right )}{e}\\ &=-\frac {2 \left (c d^2+a e^2\right )}{e^2 (e f-d g) \sqrt {d+e x}}+\frac {2 c \sqrt {d+e x}}{e^2 g}+\frac {\left (2 \left (c f^2+a g^2\right )\right ) \operatorname {Subst}\left (\int \frac {1}{-e f+d g-g x^2} \, dx,x,\sqrt {d+e x}\right )}{g (e f-d g)}\\ &=-\frac {2 \left (c d^2+a e^2\right )}{e^2 (e f-d g) \sqrt {d+e x}}+\frac {2 c \sqrt {d+e x}}{e^2 g}-\frac {2 \left (c f^2+a g^2\right ) \tan ^{-1}\left (\frac {\sqrt {g} \sqrt {d+e x}}{\sqrt {e f-d g}}\right )}{g^{3/2} (e f-d g)^{3/2}}\\ \end {align*}
________________________________________________________________________________________
Mathematica [C] time = 0.09, size = 91, normalized size = 0.81 \[ \frac {2 c (e f-d g) (2 d g+e (f+g x))-2 e^2 \left (a g^2+c f^2\right ) \, _2F_1\left (-\frac {1}{2},1;\frac {1}{2};\frac {g (d+e x)}{d g-e f}\right )}{e^2 g^2 \sqrt {d+e x} (e f-d g)} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [B] time = 0.91, size = 499, normalized size = 4.46 \[ \left [\frac {{\left (c d e^{2} f^{2} + a d e^{2} g^{2} + {\left (c e^{3} f^{2} + a e^{3} g^{2}\right )} x\right )} \sqrt {-e f g + d g^{2}} \log \left (\frac {e g x - e f + 2 \, d g - 2 \, \sqrt {-e f g + d g^{2}} \sqrt {e x + d}}{g x + f}\right ) + 2 \, {\left (c d e^{2} f^{2} g - {\left (3 \, c d^{2} e + a e^{3}\right )} f g^{2} + {\left (2 \, c d^{3} + a d e^{2}\right )} g^{3} + {\left (c e^{3} f^{2} g - 2 \, c d e^{2} f g^{2} + c d^{2} e g^{3}\right )} x\right )} \sqrt {e x + d}}{d e^{4} f^{2} g^{2} - 2 \, d^{2} e^{3} f g^{3} + d^{3} e^{2} g^{4} + {\left (e^{5} f^{2} g^{2} - 2 \, d e^{4} f g^{3} + d^{2} e^{3} g^{4}\right )} x}, \frac {2 \, {\left ({\left (c d e^{2} f^{2} + a d e^{2} g^{2} + {\left (c e^{3} f^{2} + a e^{3} g^{2}\right )} x\right )} \sqrt {e f g - d g^{2}} \arctan \left (\frac {\sqrt {e f g - d g^{2}} \sqrt {e x + d}}{e g x + d g}\right ) + {\left (c d e^{2} f^{2} g - {\left (3 \, c d^{2} e + a e^{3}\right )} f g^{2} + {\left (2 \, c d^{3} + a d e^{2}\right )} g^{3} + {\left (c e^{3} f^{2} g - 2 \, c d e^{2} f g^{2} + c d^{2} e g^{3}\right )} x\right )} \sqrt {e x + d}\right )}}{d e^{4} f^{2} g^{2} - 2 \, d^{2} e^{3} f g^{3} + d^{3} e^{2} g^{4} + {\left (e^{5} f^{2} g^{2} - 2 \, d e^{4} f g^{3} + d^{2} e^{3} g^{4}\right )} x}\right ] \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [A] time = 0.19, size = 116, normalized size = 1.04 \[ \frac {2 \, \sqrt {x e + d} c e^{\left (-2\right )}}{g} + \frac {2 \, {\left (c f^{2} + a g^{2}\right )} \arctan \left (\frac {\sqrt {x e + d} g}{\sqrt {-d g^{2} + f g e}}\right )}{{\left (d g^{2} - f g e\right )} \sqrt {-d g^{2} + f g e}} + \frac {2 \, {\left (c d^{2} + a e^{2}\right )}}{{\left (d g e^{2} - f e^{3}\right )} \sqrt {x e + d}} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [A] time = 0.02, size = 114, normalized size = 1.02 \[ \frac {-\frac {2 \left (a \,g^{2}+c \,f^{2}\right ) e^{2} \arctanh \left (\frac {\sqrt {e x +d}\, g}{\sqrt {\left (d g -e f \right ) g}}\right )}{\left (d g -e f \right ) \sqrt {\left (d g -e f \right ) g}\, g}+\frac {2 \sqrt {e x +d}\, c}{g}-\frac {2 \left (-a \,e^{2}-c \,d^{2}\right )}{\left (d g -e f \right ) \sqrt {e x +d}}}{e^{2}} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [F(-2)] time = 0.00, size = 0, normalized size = 0.00 \[ \text {Exception raised: ValueError} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 0.23, size = 124, normalized size = 1.11 \[ \frac {2\,c\,\sqrt {d+e\,x}}{e^2\,g}+\frac {2\,\left (c\,g\,d^2+a\,g\,e^2\right )}{e^2\,g\,\left (d\,g-e\,f\right )\,\sqrt {d+e\,x}}+\frac {\mathrm {atan}\left (\frac {d\,g^{3/2}\,\sqrt {d+e\,x}\,1{}\mathrm {i}-e\,f\,\sqrt {g}\,\sqrt {d+e\,x}\,1{}\mathrm {i}}{{\left (d\,g-e\,f\right )}^{3/2}}\right )\,\left (c\,f^2+a\,g^2\right )\,2{}\mathrm {i}}{g^{3/2}\,{\left (d\,g-e\,f\right )}^{3/2}} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [A] time = 87.88, size = 107, normalized size = 0.96 \[ \frac {2 c \sqrt {d + e x}}{e^{2} g} + \frac {2 \left (a g^{2} + c f^{2}\right ) \operatorname {atan}{\left (\frac {\sqrt {d + e x}}{\sqrt {- \frac {d g - e f}{g}}} \right )}}{g^{2} \sqrt {- \frac {d g - e f}{g}} \left (d g - e f\right )} + \frac {2 \left (a e^{2} + c d^{2}\right )}{e^{2} \sqrt {d + e x} \left (d g - e f\right )} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________